package com.sali.config;

/**
 * 统一的消息返回CODE码
 */
public enum ReturnCode {
    /**
     * 响应失败
     */
    ERROR(1, "Unknow error,fail to acquire data!"),

    /**
     * 参数错误
     */
    PARAMS_ERROR(22, "Check params error！"),
    /**
     * 响应成功
     */
    SUCCESS(0, "Successfully");

    private int code;

    private String message;

    ReturnCode(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
